<!DOCTYPE html>
<html>

  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>农村集体三资管理</title>
    <link rel="stylesheet" href="../frame/layui/css/layui.css">
  </head>

  <body style="height: 700px;">

      <div>
        <!-- 内容主体区域 -->
        <div style="padding: 15px;">
          <div class="layui-row layui-font-20">
            <div style="text-align: center"><h1>项目评估管理</h1></div>
            <hr />
            <table class="layui-hide" id="test"></table>
          </div>
        </div>
      </div>

    <script src="../frame/layui/layui.js"></script>
    <script>
      layui.use('table', function () {
        var table = layui.table;

        table.render({
          elem: '#test'
          , url: 'http://localhost:8080/evaluate'
          , cols: [[
            { field: 'theprojectname', width: 200, title: '项目名称' }
            , { field: 'name', width: 200, title: '负责人' }
            , { field: 'projectbudget', width: 200, title: '项目预算', sort: true }
            , { field: 'marketresearch', title: '市场调研', width: '50%', minWidth: 150 }
          ]]
          ,page:true
        });

        //如果还出现错位，用下面这段代码进行重新加载
        // table.reload('test', {
        //   data: data
        // });
      });
    </script>


    <script>
      //JS
      layui.use(['element', 'layer', 'util'], function () {
        var element = layui.element
                , layer = layui.layer
                , util = layui.util
                , $ = layui.$;
        var rand = Math.round(Math.random() * 5 + 1);
        //头部事件
        util.event('lay-header-event', {
          //左侧菜单事件
          menuLeft: function (othis) {
            layer.msg('展开左侧菜单的操作', { icon: 0 });
          }
          , menuRight: function () {
            layer.open({
              type: 1
              , btn: ['确定']
              , content: '<div style="margin-top: 10px;margin-left: 5%; width: 90%;height: 40px;line-height:40px;">版本：</div><div style="margin-top: 10px; margin-left: 5%; width: 90%;height: 40px;line-height:40px;background-color:#F5F5F5;">当前版本：V1.0</div><div style="margin-top: 20px; margin-left: 5%; width: 90%;height: 40px;line-height:40px;">更新信息：</div><div style="margin-top: 10px; margin-left: 5%; width: 90%;height: 40px;line-height:40px;background-color:#F5F5F5;">V1.0：实现基本功能</div>'
              , area: ['40%', '50%']
              , offset: 'auto' //右上角
              , shadeClose: true
              , time: 5000
              , anim: rand
            });
          }

        });

      });
    </script>


  </body>

</html>